﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using SecureCookie.Implementation.Hook.Impl;
using System.Diagnostics;

namespace SecureCookie.Implementation.Hook
{
    static class Factory
    {
        internal static IServerSideDataProvider CreateServerSideDataProvider()
        {
            return new DefaultServerSideDataProvider(CreateLogger());
        }

        internal static ILogger CreateLogger()
        {
            if (Debugger.IsAttached)
                return new Impl.DebugTraceLogger();
            return new Impl.WebContextTraceLogger();
        }
    }
}
